            <tr>
                <th>仓库设置：</th>
                <td><select name="set[ome.branch.mode]">
                    <{if $branchCount <= 1}>
                    <option value="single" <{if $setData.ome_branch_mode=='single'}>selected="selected"<{/if}>>单仓库</option>
                    <{/if}>
                    <option value="multi" <{if $setData.ome_branch_mode=='multi'}>selected="selected"<{/if}>>多仓库</option>
                </select> <{if $branchCount > 1}><span style="color:#FF0000;">注:当前仓库数量大于一个,不可切换为单一仓库</span><{/if}></td>
            </tr>
            <tr>
                <th>订单失效时间设置(分钟)：</th>
                <td><input type="text" name="set[ome.order.failtime]"  value="<{$setData.ome_order_failtime}>" vtype="required"/><{help}>未支付的款到发货订单在设置时间过后将被自动取消<{/help}></td>
            </tr>
            <tr>
                <th>API同步日志备份周期：</th>
                <td><select name="set[ome.api_log.clean_time]">
                    <option value="7" <{if $setData.ome_api_log_clean_time=='7'}>selected="selected"<{/if}>>7天</option>
                    <option value="15" <{if $setData.ome_api_log_clean_time=='15' || $setData.ome_api_log_clean_time == ''}>selected="selected"<{/if}>>半个月</option>
                    <option value="21" <{if $setData.ome_api_log_clean_time=='21'}>selected="selected"<{/if}>>21天</option>
                    <option value="31" <{if $setData.ome_api_log_clean_time=='31'}>selected="selected"<{/if}>>一个月</option>
                </select><{help}>设置天数以上的同步日志将被清除<{/help}></td>
            </tr>
            <tr>
                <th>订单未确认的时间设置(分钟)：</th>
                <td><input type="text" name="set[ome.order.unconfirmtime]"  value="<{$setData.ome_order_unconfirmtime}>" vtype="required"/><{help}>从下单时间开始计算,设置时间过后仍未被确认的订单将被加粗显示<{/help}></td>
            </tr>
            <tr>
                <th>发货校验商品名称显示方式：</th>
                <td><select name="set[ome.delivery.check_show_type]" id="delivery_check_show_type">
                    <option value="stock" <{if $setData.ome_delivery_check_show_type=='stock'}>selected="selected"<{/if}>>后台名称</option>
                    <option value="front" <{if $setData.ome_delivery_check_show_type=='front'}>selected="selected"<{/if}>>前台名称</option>
                </select></td>
            </tr>
            <tr id="delivery_check_num">
                <th>发货校验商品数量设置：</th>
                <td><input type="text" name="set[ome.delivery.check]"  value="<{$setData.ome_delivery_check}>" size="5" vtype="required&&unsignedint"/><{help}>同一货品数量大于设置数量时可以通过录入数量来批量检验<{/help}></td>
            </tr>
            <tr>
                <th>逐单发货是否称重：</th>
                <td>
                    <input class='set_delivery_weight' type="radio" name="set[ome.delivery.weight]" value="on" <{if $setData.ome_delivery_weight == 'on'}> checked<{/if}>>开启
                    <input class='set_delivery_weight' type="radio" name="set[ome.delivery.weight]" value="off" <{if $setData.ome_delivery_weight == 'off'}> checked<{/if}>>关闭
                    <{help}>开启逐单发货称重功能<{/help}>
                </td>
            </tr>
            <tr>
                <th>包裹重量范围：</th>
                <td>
                    <input  type="text" name="set[ome.delivery.minWeight]" size=10 value="<{$setData.ome_delivery_minWeight}>" vtype="required&&unsignedint"/>克 ≤ 包裹重量 ≤ 
                    <input  type="text" name="set[ome.delivery.maxWeight]" size=10 value="<{$setData.ome_delivery_maxWeight}>" vtype="required&&unsignedint"/>克
                </td>
            </tr>
<!---发货称重报警-->
            <tr class='weight_on'>
                <th>逐单发货称重报警：</th>
                <td>
                    <input type="radio" name="set[ome.delivery.weightwarn]" value="on" <{if $setData.ome_delivery_weightwarn == 'on'}> checked<{/if}>>开启
                    <input type="radio" name="set[ome.delivery.weightwarn]" value="off" <{if $setData.ome_delivery_weightwarn == 'off'}> checked<{/if}> <{if $setData.ome_delivery_weightwarn == ''}> checked<{/if}>>关闭
                    
                </td>
            </tr>
            <tr class='weightwarn_on'>
                <th>逐单发货称重报警设置：</th>
                <td>
                   包裹称重重量比系统中货品净重多出<input type="text" name="set[ome.delivery.max_weightwarn]" size="6" value="<{$setData.ome_delivery_max_weightwarn|default:0}>" vtype="required&&unsignedint">&nbsp;&nbsp;<span id='warnunit1' style="width:20px;"><{if $setData.ome_delivery_maxpercent=='1'}>%<{else}>g<{/if}></span><input type="hidden" id="maxpercent" name="set[ome.delivery.maxpercent]" value="<{$setData.ome_delivery_maxpercent|default:0}>">&nbsp;&nbsp;以上,进行报警<input type="checkbox" class='weightpercent' value="1" <{if $setData.ome_delivery_maxpercent=='1'}>checked<{/if}>>按百分比计算
                    
                </td>
            </tr>
          
            <tr class='weightwarn_on'>
                <th></th>
                <td>
                   包裹称重重量比系统中货品净重少了<input type="text" name="set[ome.delivery.min_weightwarn]" size="6" value="<{$setData.ome_delivery_min_weightwarn|default:0}>" vtype="required&&unsignedint">&nbsp;&nbsp;<span id='warnunit2' ><{if $setData.ome_delivery_minpercent=='1'}>%<{else}>g<{/if}></span><input type="hidden" id="minpercent" name="set[ome.delivery.minpercent]" value="<{$setData.ome_delivery_minpercent|default:0}>">&nbsp;&nbsp;以上,进行报警<input type="checkbox" class='weightpercent' value="2" <{if $setData.ome_delivery_minpercent=='1'}>checked<{/if}>>按百分比计算<font  color="red">(多物流单包裹不适用此范围报警)</font>
                    
                </td>
            </tr>

            <tr class='weightwarn_on'>
                <th>仓库对问题包裹的处理权限：</th>
                <td>
                   <input type="radio" name="set[ome.delivery.problem_package]" value="1" <{if $setData.ome_delivery_problem_package == '1'}> checked<{/if}>>可选择仍然发货或退回检查<{help}>包裹重量不变的情况下,仓库可以选择对问题包裹进行发货操作或退回检查<{/help}><font color='red'>可制作并扫入“确认”和“取消”之条形码来控制</font><br><input type="radio" name="set[ome.delivery.problem_package]" value="0" <{if $setData.ome_delivery_problem_package == '0'}> checked<{/if}> <{if $setData.ome_delivery_problem_package == ''}> checked<{/if}>>只能退回检查<{help}>包裹重量不变的情况下，需要修改商品重量或报警设置，才能对问题包裹进行发货<{/help}><font color='red'>可按键盘任意键或扫入任意条码来控制</font>
                    
                </td>
            </tr>
<!---发货称重报警-->
            <tr>
                <th>打印是否检验批次号：</th>
                 <td><select name="set[ome.delivery.check_ident]">
                    <option value="on" <{if $setData.ome_delivery_check_ident=='on'}>selected="selected"<{/if}>>开启</option>
                    <option value="off" <{if $setData.ome_delivery_check_ident=='off'}>selected="selected"<{/if}>>关闭</option>
                </select></td>   
            </tr>
            <tr>
                <th>条形码唯一码合并：</th>
                <td>
                    <input type="radio" onchange="check(1)" name="set[ome.product.serial.merge]" value="false" <{if $setData.ome_product_serial_merge == 'false'}> checked<{/if}>>关闭
                    <input type="radio" onchange="check(1)" name="set[ome.product.serial.merge]" value="true" <{if $setData.ome_product_serial_merge == 'true'}> checked<{/if}>>开启
                    <{help}>开启条形码唯一码合并<{/help}>
                    <span id="serial_separate">
                        设置分隔符：<input type="text" name="set[ome.product.serial.separate]" size=6 value="<{$setData.ome_product_serial_separate}>" vtype="required" />
                        <span class="red">请用一个特殊字符作为分隔符</span>
                    </span>
                </td>
            </tr>
            <tr>
                <th>唯一码发货回传</th>
                <td>
                    <input type="radio" name="set[ome.product.serial.delivery]" value="false" <{if $setData.ome_product_serial_delivery == 'false'}> checked<{/if}>>关闭
                    <input type="radio" name="set[ome.product.serial.delivery]" value="true" <{if $setData.ome_product_serial_delivery == 'true'}> checked<{/if}>>开启
                </td>
            </tr>
            <tr>
                <th>是否忽略淘宝拍拍店铺定义的EMS配送方式并在备注中标记：</th>
                <td>
                    <input type="radio" name="set[ome.checkems]" value="false" <{if $setData.ome_checkems == 'false'}> checked<{/if}>>关闭
                    <input type="radio" name="set[ome.checkems]" value="true" <{if $setData.ome_checkems == 'true'}> checked<{/if}>>开启
                </td>
            </tr>
            <tr>
                <th>发货配置：</th>
                <td>
                    <input type="radio" name="set[ome.delivery.cfg.radio]" value="1" <{if $setData.ome_delivery_cfg_radio != '2'}> checked<{/if}>>经典打印
                    <input type="radio" name="set[ome.delivery.cfg.radio]" value="2" <{if $setData.ome_delivery_cfg_radio == '2'}> checked<{/if}>>按品类打印
                    <{help}>此选项控制发货配置<{/help}>
                </td>
            </tr>
            <tr>
                <th>订单金额为0元的是否需要经过付款确认：</th>
                <td>
                    <{input type='bool' name='set[ome.payment.confirm]' value=$setData.ome_payment_confirm|default:'false'}>
                </td>
            </tr>
            
            <tr>
                <th>分组校验时间间隔设置(分钟)：</th>
                <td><input type="text" size="10"  id="groupCalibration" name="set[ome.groupCalibration.intervalTime]"  value="<{$setData.ome_groupCalibration_intervalTime}>" vtype="required"/><{help}>执行分组校验时，检测上一次分组校验的执行时间，设置间隔时间，防止短时间执行该操作发生错误！(时间间隔最短2分钟)<{/help}></td>
            </tr>
            
            <tr>
                <th>分组发货时间间隔设置(分钟)：</th>
                <td><input type="text" size="10"  id="groupDelivery" name="set[ome.groupDelivery.intervalTime]"  value="<{$setData.ome_groupDelivery_intervalTime}>" vtype="required"/><{help}>执行分组发货时，检测上一次分组发货的执行时间，设置间隔时间，防止短时间执行该操作发生错误！(时间间隔最短2分钟)<{/help}></td>
            </tr>
            
            <tr>
                <th>未分派的订单-订单获取时间间隔设置(分钟)：</th>
                <td><input type="text" size="10"  id="getOrder" name="set[ome.getOrder.intervalTime]"  value="<{$setData.ome_getOrder_intervalTime}>" vtype="required"/><{help}>执行未分派的订单中的订单获取时，检测上一次操作改功能的执行时间，设置间隔时间，防止短时间执行该操作发生错误！(时间间隔最短2分钟)<{/help}></td>
            </tr>
			
			<tr>
                <th>执行发货方式：</th>
                <td><input type="radio" name="set[ome.delivery.method]" value="on" <{if $setData.ome_delivery_method == 'on'}> checked<{/if}>>启用
                    <input type="radio" name="set[ome.delivery.method]" value="off" <{if $setData.ome_delivery_method == 'off'}> checked<{/if}>>不启用 <span style="color:#FF0000;">启用【在线下单】方式执行发货操作 (如果不启用，默认使用【自己联系物流】方式执行发货操作) 该方式只针对淘宝</span></td>
            </tr>
<script>

$('groupCalibration').addEvent('keyup',function(e){
    if(this.value.length==1){
        this.value=this.value.replace(/[^1-9]/g,'')
    }else{
        this.value=this.value.replace(/\D/g,'')
    };
    var FirstChar=this.value.substr(0,1);
    if(FirstChar=="0")
    {
       this.value=2; 
    }
    if(this.value<2){
        this.value=2; 
    }
});
$('groupCalibration').addEvent('afterpaste',function(e){
    if(this.value.length==1){
        this.value=this.value.replace(/[^1-9]/g,'')
    }else{
        this.value=this.value.replace(/\D/g,'')
    };
    var FirstChar=this.value.substr(0,1);
    if(FirstChar=="0")
    {
       this.value=2; 
    }
    if(this.value<2){
        this.value=2; 
    }
});

$('groupDelivery').addEvent('keyup',function(e){
    if(this.value.length==1){
        this.value=this.value.replace(/[^1-9]/g,'')
    }else{
        this.value=this.value.replace(/\D/g,'')
    };
    var FirstChar=this.value.substr(0,1);
    if(FirstChar=="0")
    {
       this.value=2; 
    }
    if(this.value<2){
        this.value=2; 
    }
});
$('groupDelivery').addEvent('afterpaste',function(e){
    if(this.value.length==1){
        this.value=this.value.replace(/[^1-9]/g,'')
    }else{
        this.value=this.value.replace(/\D/g,'')
    };
    var FirstChar=this.value.substr(0,1);
    if(FirstChar=="0")
    {
       this.value=2; 
    }
    if(this.value<2){
        this.value=2; 
    }
});



function check(status){
    if(status == 1){
        if($$('input[name=set[ome.product.serial.merge]]:checked').get('value') == 'true'){
            $('serial_separate').show();
        }else{
            $('serial_separate').hide();
        }
    }
}
check(1);


function delivery_weight(setting) {
    if(setting=='on') {
        $$('.weight_on').setStyle('display','');
        $$('.weightwarn_on').setStyle('display','');
    } else {
        $$('.weight_on').setStyle('display','none');
        $$('.weightwarn_on').setStyle('display','none');
    }
}
$$('input[name=set[ome.delivery.weight]]').addEvent('click',function(e){

    
    delivery_weight(this.value);
});
var set_delivery_weight = $$('input[name=set[ome.delivery.weight]]:checked').get('value');

delivery_weight(set_delivery_weight);

function delivery_weightwarn(setting) {
    if (setting=='on') {
        $$('.weightwarn_on').setStyle('display','');
        
    } else {
        $$('.weightwarn_on').setStyle('display','none');
    }
}



$$('input[name=set[ome.delivery.weightwarn]]').addEvent('click',function(e){
    delivery_weightwarn(this.value)

});



function weight_warnunit(setting,id) {
    if(setting==true){
        $('warnunit'+id).set('html','%');
        if(id=='1'){
            $('maxpercent').set('value',1);
        }else{
            $('minpercent').set('value',1);
        }
    }else{
        $('warnunit'+id).set('html','g');
        if(id=='1'){
            $('maxpercent').set('value',0);
        }else{
            $('minpercent').set('value',0);
        }
    }
}
$$('.weightpercent').addEvent('click',function(e){
    
   weight_warnunit(this.checked,this.value);
});

var weightwarn = $$('input[name=set[ome.delivery.weightwarn]]:checked').get('value');

if(weightwarn){
    delivery_weightwarn(weightwarn);
}else{
    delivery_weightwarn('off');
    
}



</script>